Skip to content

feat: improve export defaults, discoverability, and resume error handling#3

Merged
andyhtran merged 2 commits intomainfrom
feat/export-improvements
Mar 9, 2026
Merged

feat: improve export defaults, discoverability, and resume error handling#3
andyhtran merged 2 commits intomainfrom
feat/export-improvements

Conversation

@andyhtran
Copy link
Copy Markdown
Owner

Summary

  • Export no longer truncates conversation text by default--max-chars now defaults to 0 instead of 500, so full assistant responses are shown
  • Selective tool result truncation — new --max-tool-chars flag (default 2000) truncates tool blocks independently while conversation text stays full
  • --full means "show everything" — disables all truncation and includes tool results (previously only controlled truncation)
  • --short flag for compact output (truncates to 500 chars)
  • Contextual stderr hints — when tool blocks are skipped or messages are truncated, hints suggest the right flag (e.g., hint: 6 tool block(s) skipped (use --include-tool-results or --full to include))
  • CCT_NO_HINTS env var to suppress hints
  • Truncation indicator — truncated text shows [+N chars] instead of just ...
  • Resume error handlingos.Stat errors other than "not exist" (e.g., permission denied) now return a clear error instead of silently proceeding

Test plan

  • Verified default export shows complete conversation text without truncation
  • Verified --short truncates with [+N chars] indicator
  • Verified --full includes tool results and disables all truncation
  • Verified --include-tool-results with --max-tool-chars truncates tool blocks independently
  • Verified hints appear on stderr and do not pollute stdout when piped
  • Verified CCT_NO_HINTS=1 suppresses hints
  • Verified resume handles non-existent directories, permission errors, and normal directories correctly
  • All unit tests pass (just ci)

🤖 Generated with Claude Code

andyhtran and others added 2 commits March 8, 2026 22:45
Default export no longer truncates conversation text. Tool results are
truncated independently (--max-tool-chars, default 2000) while conversation
text stays full. --full now acts as "show everything" (no truncation + include
tool results). Contextual hints on stderr guide users to relevant flags when
content is skipped or truncated.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
When resuming a session whose project directory no longer exists (e.g.
renamed or deleted), create the directory automatically instead of
erroring out. This lets users resume sessions to review history even
when the original project path is gone.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@andyhtran andyhtran merged commit 6c8634b into main Mar 9, 2026
3 checks passed
@andyhtran andyhtran deleted the feat/export-improvements branch March 9, 2026 02:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant